<?php

namespace Api\Openapi;

/**
 * Class Baddress
 * Author zly
 * @package Api\Openapi
 * @description 银行卡归属地sdk
 *
 * 使用示范
 *
 *
 * $sdk = new \Api\Openapi\Baddress();
 * $result = $sdk->queryBankAddress('6222021203016617804');
 */

class Baddress {

    const URI_TRAVEL_AREO_INFO = '/bankmatch/bankaddress';

    /**
     * 查询银行卡归属地
     *
     * @param string $card_num 银行卡号
     *
     * @return mixed
     */
    public function queryBankAddress($card_num) {
        $body = array(
            'card_num' => $card_num
        );
        $param = array(
            'header' => array(),
            'body'   => $body,
        );

        $result = Util::request(self::URI_TRAVEL_AREO_INFO, $param);

        return $result["body"];
    }
}